import config from "@/config"
import http from "@/utils/request"

export default {
	list: {
		url: `${config.API_URL}/merchant/seckill/index`,
		name: "获取用秒杀列表",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	},
	add: {
		url: `${config.API_URL}/merchant/seckill/add`,
		name: "新增秒杀",
		post: async function(data={}){
			return await http.post(this.url, data);
		}
	},
	getAddInfo: {
		url: `${config.API_URL}/merchant/seckill/add`,
		name: "获取秒杀信息",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	},
	edit: {
		url: `${config.API_URL}/merchant/seckill/edit`,
		name: "编辑秒杀",
		post: async function(data={}){
			return await http.post(this.url, data);
		}
	},
	getEditInfo: {
		url: `${config.API_URL}/merchant/seckill/edit`,
		name: "获取秒杀信息",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	},
	del: {
		url: `${config.API_URL}/merchant/seckill/del`,
		name: "删除秒杀",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	},
	shelf: {
		url: `${config.API_URL}/merchant/seckill/shelf`,
		name: "上下架",
		post: async function(data={}){
			return await http.post(this.url, data);
		}
	}
}
